{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 1,
   "metadata": {},
   "outputs": [],
   "source": [
    "import pandas as pd"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "metadata": {},
   "outputs": [],
   "source": [
    "import numpy as np"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "metadata": {},
   "outputs": [],
   "source": [
    "import os"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "metadata": {},
   "outputs": [],
   "source": [
    "dir_content = os.listdir()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 5,
   "metadata": {},
   "outputs": [],
   "source": [
    "dir_content = [filename for filename in dir_content if filename.find('cart-pole-v1') > -1]"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 6,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "['1524748921-cart-pole-v1.csv']"
      ]
     },
     "execution_count": 6,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "dir_content"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 7,
   "metadata": {},
   "outputs": [],
   "source": [
    "df = pd.read_csv(dir_content[0])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 8,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>Unnamed: 0</th>\n",
       "      <th>actions-input</th>\n",
       "      <th>rewards</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>0</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>1</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>2</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>3</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>4</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>5</th>\n",
       "      <td>5</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>6</th>\n",
       "      <td>6</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>7</th>\n",
       "      <td>7</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8</th>\n",
       "      <td>8</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>9</th>\n",
       "      <td>9</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>10</th>\n",
       "      <td>10</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>11</th>\n",
       "      <td>11</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>12</th>\n",
       "      <td>12</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>13</th>\n",
       "      <td>13</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>15</th>\n",
       "      <td>15</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>16</th>\n",
       "      <td>16</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>17</th>\n",
       "      <td>17</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>18</th>\n",
       "      <td>18</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>19</th>\n",
       "      <td>19</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>20</th>\n",
       "      <td>20</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>21</th>\n",
       "      <td>21</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>22</th>\n",
       "      <td>22</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>23</th>\n",
       "      <td>23</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>24</th>\n",
       "      <td>24</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>26</th>\n",
       "      <td>26</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>27</th>\n",
       "      <td>27</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>28</th>\n",
       "      <td>28</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>29</th>\n",
       "      <td>29</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>30</th>\n",
       "      <td>30</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>31</th>\n",
       "      <td>31</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>144</th>\n",
       "      <td>144</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>145</th>\n",
       "      <td>145</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>146</th>\n",
       "      <td>146</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>147</th>\n",
       "      <td>147</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>148</th>\n",
       "      <td>148</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>149</th>\n",
       "      <td>149</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>150</th>\n",
       "      <td>150</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>151</th>\n",
       "      <td>151</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>152</th>\n",
       "      <td>152</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>153</th>\n",
       "      <td>153</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>154</th>\n",
       "      <td>154</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>155</th>\n",
       "      <td>155</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>156</th>\n",
       "      <td>156</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>157</th>\n",
       "      <td>157</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>158</th>\n",
       "      <td>158</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>159</th>\n",
       "      <td>159</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>160</th>\n",
       "      <td>160</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>161</th>\n",
       "      <td>161</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>162</th>\n",
       "      <td>162</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>163</th>\n",
       "      <td>163</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>164</th>\n",
       "      <td>164</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>165</th>\n",
       "      <td>165</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>166</th>\n",
       "      <td>166</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>167</th>\n",
       "      <td>167</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>168</th>\n",
       "      <td>168</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>169</th>\n",
       "      <td>169</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>170</th>\n",
       "      <td>170</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>171</th>\n",
       "      <td>171</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>172</th>\n",
       "      <td>172</td>\n",
       "      <td>0</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>173</th>\n",
       "      <td>173</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>166 rows × 3 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "     Unnamed: 0  actions-input  rewards\n",
       "0             0              1      1.0\n",
       "1             1              1      1.0\n",
       "2             2              1      1.0\n",
       "3             3              0      1.0\n",
       "4             4              0      1.0\n",
       "5             5              1      1.0\n",
       "6             6              1      1.0\n",
       "7             7              0      1.0\n",
       "8             8              1      1.0\n",
       "9             9              1      1.0\n",
       "10           10              0      1.0\n",
       "11           11              0      1.0\n",
       "12           12              1      1.0\n",
       "13           13              0      1.0\n",
       "15           15              1      1.0\n",
       "16           16              1      1.0\n",
       "17           17              1      1.0\n",
       "18           18              1      1.0\n",
       "19           19              0      1.0\n",
       "20           20              0      1.0\n",
       "21           21              1      1.0\n",
       "22           22              1      1.0\n",
       "23           23              0      1.0\n",
       "24           24              0      1.0\n",
       "26           26              0      1.0\n",
       "27           27              1      1.0\n",
       "28           28              1      1.0\n",
       "29           29              1      1.0\n",
       "30           30              0      1.0\n",
       "31           31              0      1.0\n",
       "..          ...            ...      ...\n",
       "144         144              1      1.0\n",
       "145         145              1      1.0\n",
       "146         146              0      1.0\n",
       "147         147              0      1.0\n",
       "148         148              1      1.0\n",
       "149         149              0      1.0\n",
       "150         150              0      1.0\n",
       "151         151              1      1.0\n",
       "152         152              0      1.0\n",
       "153         153              1      1.0\n",
       "154         154              0      1.0\n",
       "155         155              1      1.0\n",
       "156         156              0      1.0\n",
       "157         157              0      1.0\n",
       "158         158              1      1.0\n",
       "159         159              0      1.0\n",
       "160         160              0      1.0\n",
       "161         161              0      1.0\n",
       "162         162              1      1.0\n",
       "163         163              0      1.0\n",
       "164         164              0      1.0\n",
       "165         165              1      1.0\n",
       "166         166              1      1.0\n",
       "167         167              0      1.0\n",
       "168         168              0      1.0\n",
       "169         169              0      1.0\n",
       "170         170              1      1.0\n",
       "171         171              0      1.0\n",
       "172         172              0      1.0\n",
       "173         173              1      1.0\n",
       "\n",
       "[166 rows x 3 columns]"
      ]
     },
     "execution_count": 8,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df[df.rewards > 0.0]"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 9,
   "metadata": {},
   "outputs": [],
   "source": [
    "first_sequence = df['actions-input'][:316]"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 10,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "[[1, 1, 0, 0],\n",
       " [1, 0, 0, 0],\n",
       " [0, 1, 1, 0],\n",
       " [0, 1, 1, 0],\n",
       " [1, 0, 1, 0],\n",
       " [1, 1, 1, 0],\n",
       " [1, 0, 1, 0],\n",
       " [1, 1, 0, 0]]"
      ]
     },
     "execution_count": 10,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "list_sequence = first_sequence.tolist()\n",
    "treated_sequence = []\n",
    "start = 0\n",
    "incremental= 4\n",
    "limit = 4\n",
    "reversed_sequence = list_sequence[::-1]\n",
    "#reversed_sequence[start:limit]\n",
    "#reversed_sequence[limit+4:]\n",
    "reversed_sequence_len = lambda: range(len(reversed_sequence))\n",
    "for _ in reversed_sequence_len():\n",
    "    done = not reversed_sequence[start:limit]\n",
    "    if not done: treated_sequence.append(reversed_sequence[start:limit])\n",
    "    reversed_sequence = reversed_sequence[limit+incremental:]\n",
    "    start = start + incremental\n",
    "    limit = limit + incremental\n",
    "    if done: break\n",
    "treated_sequence"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 11,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Produced length of output: 8\n"
     ]
    }
   ],
   "source": [
    "print('Produced length of output: {}'.format(len(treated_sequence)))"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 12,
   "metadata": {},
   "outputs": [],
   "source": [
    "actions = np.array(treated_sequence)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 13,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "array([[1, 1, 0, 0],\n",
       "       [1, 0, 0, 0],\n",
       "       [0, 1, 1, 0],\n",
       "       [0, 1, 1, 0],\n",
       "       [1, 0, 1, 0],\n",
       "       [1, 1, 1, 0],\n",
       "       [1, 0, 1, 0],\n",
       "       [1, 1, 0, 0]])"
      ]
     },
     "execution_count": 13,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "actions"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 14,
   "metadata": {},
   "outputs": [],
   "source": [
    "second_sequence = df['rewards'][:316]"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 15,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "[[-10.0, 1.0, 1.0, 1.0],\n",
       " [1.0, 1.0, 1.0, 1.0],\n",
       " [1.0, 1.0, 1.0, 1.0],\n",
       " [1.0, 1.0, -10.0, 1.0],\n",
       " [1.0, 1.0, 1.0, -10.0],\n",
       " [1.0, 1.0, 1.0, -10.0],\n",
       " [1.0, 1.0, 1.0, 1.0],\n",
       " [1.0, 1.0, 1.0, 1.0]]"
      ]
     },
     "execution_count": 15,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "list_sequence = second_sequence.tolist()\n",
    "treated_sequence = []\n",
    "start = 0\n",
    "incremental = 4\n",
    "limit = 4\n",
    "reversed_sequence = list_sequence[::-1]\n",
    "reversed_sequence_len = lambda: range(len(reversed_sequence))\n",
    "for _ in reversed_sequence_len():\n",
    "    done = not reversed_sequence[start:limit]\n",
    "    if not done: treated_sequence.append(reversed_sequence[start:limit])\n",
    "    reversed_sequence = reversed_sequence[limit+incremental:]\n",
    "    start = start + incremental\n",
    "    limit = limit + incremental\n",
    "    if done: break\n",
    "treated_sequence"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 16,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Produced length of output: 8\n"
     ]
    }
   ],
   "source": [
    "print('Produced length of output: {}'.format(len(treated_sequence)))"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 17,
   "metadata": {},
   "outputs": [],
   "source": [
    "rewards = np.array(treated_sequence)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 18,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "array([[-10.,   1.,   1.,   1.],\n",
       "       [  1.,   1.,   1.,   1.],\n",
       "       [  1.,   1.,   1.,   1.],\n",
       "       [  1.,   1., -10.,   1.],\n",
       "       [  1.,   1.,   1., -10.],\n",
       "       [  1.,   1.,   1., -10.],\n",
       "       [  1.,   1.,   1.,   1.],\n",
       "       [  1.,   1.,   1.,   1.]])"
      ]
     },
     "execution_count": 18,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "rewards"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 19,
   "metadata": {},
   "outputs": [],
   "source": [
    "import warnings; warnings.simplefilter('ignore')"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 20,
   "metadata": {},
   "outputs": [
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "Using TensorFlow backend.\n"
     ]
    }
   ],
   "source": [
    "from keras.models import Sequential"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 21,
   "metadata": {},
   "outputs": [],
   "source": [
    "from keras.layers import Dense"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 22,
   "metadata": {},
   "outputs": [],
   "source": [
    "from sklearn import model_selection"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 23,
   "metadata": {},
   "outputs": [],
   "source": [
    "x, x_val, y, y_val = model_selection.train_test_split(rewards, actions, test_size=0.2, random_state=42)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 24,
   "metadata": {},
   "outputs": [],
   "source": [
    "model = Sequential()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 25,
   "metadata": {},
   "outputs": [],
   "source": [
    "model.add(Dense(4, input_shape=(4,)))"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 26,
   "metadata": {},
   "outputs": [],
   "source": [
    "model.compile(optimizer='rmsprop', loss='mse')"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 27,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Train on 6 samples, validate on 2 samples\n",
      "Epoch 1/10\n",
      "6/6 [==============================] - 0s 18ms/step - loss: 12.5877 - val_loss: 23.3587\n",
      "Epoch 2/10\n",
      "6/6 [==============================] - 0s 407us/step - loss: 12.4379 - val_loss: 23.1735\n",
      "Epoch 3/10\n",
      "6/6 [==============================] - 0s 470us/step - loss: 12.3303 - val_loss: 23.0196\n",
      "Epoch 4/10\n",
      "6/6 [==============================] - 0s 557us/step - loss: 12.2409 - val_loss: 22.8838\n",
      "Epoch 5/10\n",
      "6/6 [==============================] - 0s 793us/step - loss: 12.1621 - val_loss: 22.7602\n",
      "Epoch 6/10\n",
      "6/6 [==============================] - 0s 435us/step - loss: 12.0903 - val_loss: 22.6451\n",
      "Epoch 7/10\n",
      "6/6 [==============================] - 0s 618us/step - loss: 12.0235 - val_loss: 22.5366\n",
      "Epoch 8/10\n",
      "6/6 [==============================] - 0s 1ms/step - loss: 11.9604 - val_loss: 22.4332\n",
      "Epoch 9/10\n",
      "6/6 [==============================] - 0s 952us/step - loss: 11.9004 - val_loss: 22.3339\n",
      "Epoch 10/10\n",
      "6/6 [==============================] - 0s 950us/step - loss: 11.8427 - val_loss: 22.2380\n"
     ]
    },
    {
     "data": {
      "text/plain": [
       "<keras.callbacks.History at 0x7fa1eae30320>"
      ]
     },
     "execution_count": 27,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "model.fit(x, y, epochs=10, batch_size=32, validation_data=(x_val, y_val))"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 28,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "6/6 [==============================] - 0s 221us/step\n"
     ]
    }
   ],
   "source": [
    "score = model.evaluate(x, y)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 29,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "11.786948204040527"
      ]
     },
     "execution_count": 29,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "score"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 30,
   "metadata": {},
   "outputs": [],
   "source": [
    "import seaborn as sns"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 42,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "<matplotlib.axes._subplots.AxesSubplot at 0x7fa1c5cf7c50>"
      ]
     },
     "execution_count": 42,
     "metadata": {},
     "output_type": "execute_result"
    },
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAXcAAAEKCAYAAADpfBXhAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADl0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uIDIuMS4yLCBodHRwOi8vbWF0cGxvdGxpYi5vcmcvNQv5yAAAIABJREFUeJzt3Xl8VfWZ+PHPc7OSfSVkIYQsgEBYA4qg4gqoBa0b6NRatWir3eu0nZmf7dh2pq2dcdrRatWx7lsZVFQUW62Kyha2hJ0QyEYgIXvInnx/f+SmE2NCLsm9OfeePO/Xixe593455+Hk5sm53+X5ijEGpZRS9uKwOgCllFLup8ldKaVsSJO7UkrZkCZ3pZSyIU3uSillQ5rclVLKhjS5K6WUDWlyV0opG9LkrpRSNuRv1Ynj4uJMWlqaVadXSimftH379lPGmPjB2lmW3NPS0sjNzbXq9Eop5ZNEpMiVdtoto5RSNqTJXSmlbEiTu1JK2ZAmd6WUsiFN7kopZUOa3JVSyoY0uSullA1pcldKKRvS5K6UUjY06ApVEXkKuBqoMMZMH6DNYuC/gADglDHmIncGqZSdvLil2OoQhuTmc1OtDkGdBVfu3J8Glg70oohEAX8AlhtjpgE3uCc0pZRSQzVocjfGfAxUn6HJzcBaY0yxs32Fm2JTSik1RO7oc58ERIvIhyKyXURudcMxlVJKDYM7qkL6A3OBS4ExwCYR2WyMOdS3oYisBlYDpKZq/51SSnmKO+7cS4ENxpjTxphTwMfAzP4aGmMeN8bkGGNy4uMHLUeslFJqiNyR3N8AFomIv4iEAOcC+91wXKWUUkPkylTIl4DFQJyIlAI/pXvKI8aYx4wx+0XkXSAP6AKeNMbs8VzISimlBjNocjfGrHKhzYPAg26JSCml1LDpClWllLIhTe5KKWVDmtyVUsqGNLkrpZQNaXJXSikb0uSulFI2pM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ELnM9Pcz63y/lvvlAfxFnn/WHn108765t/JiKFInK98/nFIvKxiLwt3TXjHxMRh/O1xl7Hut55jPPpXgX7oPPcGZ67smo00OSuvNntxpi5QA7dq0UTgCeA64wxM4EbjDHHgMeAh5x1tDf2OcazwI+MMTOAfLpXFvbwN8bMB77b6/m7gd8ZY2Y5z1vqQpyJwCLgarpXRveYD3yL7nrxGcCXBzqAMeYzupf23+f8f9itvpEaYZrclTf7tojsBjbTXaxqNfCxMeYogDHmjPW1RSQSiDLGfOR86hngwl5N1jr/3g6kOb/eBPyTiPyI7ip/zS7E+boxpstZuqJ3aemtznrxncBLdP8CUGpEaHJXXklEFgOXAQucd+k7gV1uPk2r8+9OnHWWjDEv0t090gysF5FLROQe+b/t05LOcByA3huc9B3QMv08Hzzk6JU6A03uyltF0r3tX5OITAHOozsRXigiE6F7n1xn2wYgvO8BjDF1QE1PfzrwFeCjvu16c9b1LzTG/J7uSqIzjDGP9No+7fhZ/B/mO6tOOoCbgE+cz58UkXOcz1/bq32//w+lhkKTu/JW7wL+IrKf7n7szUAl3V0za53dNa84274JXNszoNrnOF+le5AyD5gFDLa35Y3AHhHZBUynu89+qLYBD9NdKvgo8Jrz+R8DbwGfAb3L5b4M3CciO3VAVQ2XToVUygOc3Uo/NMZcbXUsanTSO3ellLIhvXNXSikb0jt3pZSyIU3uSillQ5rclVLKhjS5K6WUDWlyV0opG9LkrpRSNvT/AXBHuxaNsZ3OAAAAAElFTkSuQmCC\n",
      "text/plain": [
       "<matplotlib.figure.Figure at 0x7fa1c5d0eac8>"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    }
   ],
   "source": [
    "sns.distplot(df['actions-input'].head(n=100+1))"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 43,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "<matplotlib.axes._subplots.AxesSubplot at 0x7fa1c5cf7da0>"
      ]
     },
     "execution_count": 43,
     "metadata": {},
     "output_type": "execute_result"
    },
    {
     "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XkX0S+ByYAFv9hD4S3e/3N1nE+0W9vaY+ZcRvWrxi8A/A8+7+0yifRdNDNosAg64+2x3vwT4bVJ+UpFe6M9LCZO97v6Smb2P6I1P/hR0FZIFvOju7Wb2hplNJ9rJ1neAdxO98cRzwTwuMbN/BUYAw4E1MfP/hbt3BM/fTbTzNNz9N2Z2PBj/CvBtM7ub6I0fnkMkBRTuEiYng/8N+J27L+umzR+BG4DTwDNE+8lJB74UTL8f+IC7bw56Zry6m/n3yN1fN7O5RPst+Vcz+293v6vPP4nIedJuGQmjl4B3mdmFcGY/+LRg2nPA54luydcRvXnERbzZo2I+cDDoHvbWsyzjj8AtwfxvAEYGz0uAZnd/EPgmMDeRP5hIvLTlLqHj7nXBVvfDMbdV/CrRHgzXAmN5s9/zLcA4f7MHvX8K2tQF/+f3sJh/Cea/FXgB2BeMvxT4pplFiP518KlE/VwifaFeIUVEQki7ZUREQkjhLiISQgp3EZEQUriLiISQwl1EJIQU7iIiIaRwFxEJIYW7iEgI/X8yl8aC8UB+EwAAAABJRU5ErkJggg==\n",
      "text/plain": [
       "<matplotlib.figure.Figure at 0x7fa1c5ca04a8>"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    }
   ],
   "source": [
    "sns.distplot(df['rewards'].head(n=100+1))"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 31,
   "metadata": {},
   "outputs": [],
   "source": [
    "#!python ../app.py --environment_name \"Pong-v0\" --output_stats_filename \"pong-v0\""
   ]
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.6.4"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 2
}
